{% extends 'admin-v2/layout.html.twig' %}

{% do script(['app/js/admin-v2/operating/group/recommend-list/index.js']) %}

{% set menu = 'admin_v2_operation_group_recommend_list' %}

{% block main %}

  <form id="message-search-form" class="form-inline well well-sm" action="" method="get" novalidate>

    <div class="form-group">
      <input class="form-control" type="text" placeholder="{{ 'admin.operation_group.group_title.placeholer'|trans }}" name="title" value="{{ app.request.get('title') }}">
    </div>

    <div class="form-group">
      <input class="form-control" type="text" placeholder="{{ 'admin.operation_group.ownerName.placeholer'|trans }}" name="ownerName" value="{{ app.request.get('ownerName') }}">
    </div>

    <button class="btn btn-primary">{{ 'form.btn.search'|trans }}</button>

  </form>

  <table class="table table-striped table-hover mtl" id="group-recommend-table">
    <thead>
    <tr>
      <th>{{ 'admin.course_manage.recommend.seq'|trans }}</th>
      <th width="20%">{{ 'admin.operation_group.group_name_th'|trans }}</th>
      <th>{{ 'admin.operation_group.ownerName_th'|trans }}</th>
      <th>{{ 'admin.course_manage.recommend.time'|trans }}</th>
      <th>{{ 'admin.course_manage.operater'|trans }}</th>
    </tr>
    </thead>
    <tbody>
    {% for group in groups %}
      {% include 'admin-v2/operating/group/recommend-table-tr.html.twig' %}
    {% else %}
      <tr>
        <td colspan="20">
          <div class="empty">{{ 'admin.operation_group.recommend.empty'|trans }}</div>
        </td>
      </tr>
    {% endfor %}
    </tbody>
  </table>

  {{ admin_macro.paginator(paginator) }}

{% endblock %}